home *** CD-ROM | disk | FTP | other *** search
/ Ray Dream Studio 5 / Ray Dream.iso / pc / DreamSDK / Windows / INCLUDES / ISHWF.H < prev    next >
Encoding:
C/C++ Source or Header  |  1997-07-11  |  2.3 KB  |  76 lines

  1. /* $Id: IShWF.h 1.8 1997/03/12 23:01:37 psq-pc Exp $ */
  2. #ifndef __ISHWF__
  3. #define __ISHWF__
  4.  
  5. #ifndef __3DBSTYPE__
  6. #include "3DBSType.h"
  7. #endif
  8.  
  9. #ifndef __RCOMPOBJ__
  10. #include "RCompObj.h"
  11. #endif
  12.  
  13. DEFINE_GUID(IID_I3DShWireFrame, 0x5daccff0, 0x7edc, 0x11d0, 0xbf, 0x67, 0x0, 0xa0, 0xc9, 0xa, 0x7c, 0xb);
  14. DEFINE_GUID(IID_I3DExWireFrame, 0x5daccff1, 0x7edc, 0x11d0, 0xbf, 0x67, 0x0, 0xa0, 0xc9, 0xa, 0x7c, 0xb);
  15.  
  16. enum {kWFNone=0x0, kWFSquareHandle=0x1, kWFRoundHandle=0x2, kWFEmptySquareHandle=0x3, kWFEmptyRoundHandle=0x4};
  17. enum {kWFShift=0x1, kWFCommand=0x2, kWFOption=0x4, kWFControl=0x8};
  18.  
  19. struct WFPoint {
  20.     short fType;
  21.     VECTOR3D fLoc;
  22.     VECTOR3D fScreenLoc;
  23.     };
  24.  
  25. struct WFConnection {
  26.     long fFromPoint;
  27.     long fToPoint;
  28.     };
  29.  
  30. struct WFData {
  31.     short fNumPoints;
  32.     short fNumConnections;
  33.     WFPoint* fPoints;
  34.     WFConnection* fConnections;
  35.     };
  36.  
  37. struct FacetMesh;
  38. struct I3DFacetCache;
  39. struct I3DShTreeElement;
  40.  
  41. DECLARE_INTERFACE_(I3DShWireFrame, IUnknown) {
  42.     STDMETHOD(GetWireFrame) (WFData& aWireFrame) PURE;
  43.     STDMETHOD(GetFMesh) (FacetMesh& aMesh) PURE;
  44.     STDMETHOD(SetFCache) (void *theView,I3DFacetCache *aFCache) PURE;
  45.     STDMETHOD(GetFCache) (void *theView,I3DFacetCache *&aFCache) PURE;
  46. //-- Mesh
  47.     STDMETHOD(AllocateFMesh) (long numFacets, long numVertices, long facetStreamSize) PURE;
  48. //-- WireFrame
  49.     STDMETHOD(AllocateWireFrame) (short numPoints, short numConnections) PURE;
  50.     STDMETHOD(Connect) (short point, short from, short to) PURE;
  51.     STDMETHOD(SetPoint) (short point, short type, const VECTOR3D& loc) PURE;
  52.     STDMETHOD(GetScreen2DBox) (BOX2D& box) PURE;
  53.     STDMETHOD_(short, TestHit) (const VECTOR2D& point, NUM3D error) PURE;
  54.     };
  55.  
  56. struct TRACKINFO {
  57.     VECTOR2D fScreenLoc;
  58.     VECTOR3D fGlobalLoc;
  59.     VECTOR3D fGlobalOrthoLoc ;
  60.     VECTOR2D fHitLoc;
  61.     VECTOR2D fHitOrthoLoc;
  62.     VECTOR3D fLoc;
  63.     VECTOR3D fOrthoLoc;
  64.     VECTOR3D fRayDirection;
  65.     VECTOR3D fRayStart;
  66.     long fModifiers;
  67.     };
  68.  
  69. DECLARE_INTERFACE_(I3DExWireFrame, IUnknown) {
  70.     STDMETHOD(TrackWireFrame) (I3DShWireFrame* wireFrame, short proj, I3DShTreeElement* tree, short handle, const TRACKINFO& startinfo, const TRACKINFO& previnfo, const TRACKINFO& nextinfo) PURE;
  71.     STDMETHOD(DataToWireFrame) (I3DShWireFrame* wireFrame, short proj, I3DShTreeElement* tree) PURE;
  72.     STDMETHOD(WireFrameToData) (I3DShWireFrame* wireFrame, short proj, I3DShTreeElement* tree) PURE;
  73.     };
  74.  
  75. #endif
  76.